(19)
(11)EP 3 697 031 A1

(12)EUROPEAN PATENT APPLICATION

(43)Date of publication:
19.08.2020 Bulletin 2020/34

(21)Application number: 20168399.2

(22)Date of filing:  14.12.2016
(51)Int. Cl.: 
H04L 12/40  (2006.01)
H04L 29/06  (2006.01)
H04L 12/26  (2006.01)
H04W 4/48  (2018.01)
H04L 12/28  (2006.01)
G06F 21/85  (2013.01)
H04L 12/24  (2006.01)
H04W 12/00  (2009.01)
(84)Designated Contracting States:
AL AT BE BG CH CY CZ DE DK EE ES FI FR GB GR HR HU IE IS IT LI LT LU LV MC MK MT NL NO PL PT RO RS SE SI SK SM TR
Designated Validation States:
MA MD

(30)Priority: 08.01.2016 JP 2016003035
31.10.2016 JP 2016212574

(62)Application number of the earlier application in accordance with Art. 76 EPC:
16883746.6 / 3402128

(71)Applicant: Panasonic Intellectual Property Corporation of America
Torrance, CA 90503 (US)

(72)Inventors:
  • UJIIE, Yoshihiro
    Osaka-shi, Osaka 540-6207 (JP)
  • HAGA, Tomoyuki
    Osaka-shi, Osaka 540-6207 (JP)
  • MAEDA, Manabu
    Osaka-shi, Osaka 540-6207 (JP)
  • MATSUSHIMA, Hideki
    Osaka-shi, Osaka 540-6207 (JP)
  • KISHIKAWA, Takeshi
    Osaka-shi, Osaka 540-6207 (JP)
  • TSURUMI, Junichi
    Osaka-shi, Osaka 540-6207 (JP)
  • KASHIMA, Hisashi
    Osaka-shi, Osaka 540-6207 (JP)
  • TORIUMI, Yukino
    Osaka-shi, Osaka 540-6207 (JP)
  • KUWAHARA, Takuya
    Osaka-shi, Osaka 540-6207 (JP)

(74)Representative: Grünecker Patent- und Rechtsanwälte PartG mbB 
Leopoldstraße 4
80802 München
80802 München (DE)

 
Remarks:
This application was filed on 07-04-2020 as a divisional application to the application mentioned under INID code 62.
 


(54)ABNORMALITY DETECTION METHOD, ABNORMALITY DETECTION DEVICE, AND ABNORMALITY DETECTION SYSTEM


(57) An abnormality detection method is provided for detecting an abnormality that may be transmitted to a bus in an on-board network system including a plurality of electronic control units that transmit and receive messages via the bus in a vehicle according to a CAN protocol.
In the abnormality detection method, for example, a gateway transmits vehicle identification information to a server and receives a response thereto thereby determining a detection window size, and performs an operation process using feature information based on the number of messages received from the bus within the determined unit time and using a particular model indicating a criterion in terms of a message occurrence frequency and making a judgment as to an abnormality according to a result of the operation process.




Description

Technical Field



[0001] The present disclosure relates to a technique of detecting an abnormality in a message transmitted in an on-board network.

Background Art



[0002] In systems in vehicles according to recent techniques, many apparatuses called electronic control units (ECUs) are installed. A network via which those ECUs are connected is called an on-board network. There are many standards regarding on-board networks. Among those standards, one of the most major on-board network standards is the CAN (Controller Area Network) standard defined in ISO11898-1.

[0003] In CAN, a bus (a CAN bus) including two wires is used as a communication channel, and ECUs connected to the bus are called nodes. Each node connected to the CAN bus transmits and receives a frame (a message). Furthermore, in CAN, no identifier exists to indicate a transmission destination or a transmission source. A transmission node transmits frames each of which is attached with an ID called a message ID (that is, the transmission node performs broadcasting by transmitting a signal to the bus). Each reception node receives only a predetermined message ID (that is, reads a signal from the bus). In a system in a vehicle, each of many ECUs transmits and receives various frames.

[0004] There is a possibility that an attacker connects an invalid node to a CAN bus or attacks a portable information terminal or an ECU or the like having a capability of communicating with a communication apparatus outside a vehicle such that the attacked portable information terminal or the ECU is converted to an invalid node, and the attacker transmits an attack frame to the CAN bus to invalidly control the vehicle. The attack frame is a frame that is transmitted by a malicious attacker to the CAN bus and is such a frame (an abnormal message) that is not transmitted when the on-board network is in a normal state.

[0005] As one of techniques to detect an attack frame such as that described above, it is known to make a judgment using a statistical method as to whether a frame transmitted on a CAN bus is an abnormal frame or not (see PTL 1 and PTL 2).

Citation List


Patent Literature



[0006] 

PTL 1: Japanese Unexamined Patent Application Publication No. 2015-026252

PTL 2: Japanese Unexamined Patent Application Publication No. 2015-170121


Summary of Invention


Technical Problem



[0007] The techniques disclosed in PTL 1 and PTL 2 are not necessarily effective enough to detect an attack frame (that is, to detect an abnormality) on an on-board network, and thus there is a need for further research and development of techniques for detecting an abnormality.

[0008] In view of the above, the present disclosure provides an abnormality detection method useful for detecting an abnormal message (an attack frame) that may occur in an on-board network in a vehicle such as a car or the like. Solution to Problem

[0009] To solve the above problem, an aspect of the present disclosure provides an abnormality detection method for detecting an abnormality in an on-board network system, the on-board network system including a plurality of electronic control units that transmit and receive messages via a bus in a vehicle according to a CAN (Controller Area Network) protocol, the abnormality detection method including determining a unit time, and judging whether there is an abnormality according to a result of an operation process performed using feature information and a particular model indicating a criterion in terms of a message occurrence frequency, the feature information determined based on the number of messages received from the bus within the determined unit time.

[0010] General or specific embodiments may be implemented by an apparatus, a system, an integrated circuit, a computer program, a computer-readable storage medium such as a CD-ROM, or any selective combination of an apparatus, a system, a method, a computer program, and a storage medium. Advantageous Effects of Invention

[0011] According to the present disclosure, if an attack frame (message) is transmitted to a bus by an attacker, this can lead to a change such that the number of messages received within the unit time determined in the on-board network system is different from the criterion, and thus it is possible to detect an abnormality.

[0012] Additional benefits and advantages of the present disclosure will become apparent from the specification and drawings. The benefits and advantages may be individually obtained by the various embodiments and features of the specification and drawings. However, it does not necessarily need to provide all such benefits and advantages.

Brief Description of Drawings



[0013] 

[Fig. 1] Fig. 1 is a diagram illustrating a total configuration of an abnormality detection system according to a first embodiment.

[Fig. 2] Fig. 2 is a diagram illustrating a data frame format according to the CAN protocol.

[Fig. 3] Fig. 3 is a diagram illustrating a configuration of an electronic control unit (ECU).

[Fig. 4] Fig. 4 is a diagram illustrating an example of an acceptance ID list.

[Fig. 5] Fig. 5 is a diagram illustrating examples of sets each including an ID and a data field for frames transmitted from an engine ECU.

[Fig. 6] Fig. 6 is a diagram illustrating examples of sets each including an ID and a data field for frames transmitted from a brake ECU.

[Fig. 7] Fig. 7 is a diagram illustrating examples of sets each including an ID and a data field for frames transmitted from a door open/close sensor ECU.

[Fig. 8] Fig. 8 is a diagram illustrating examples of sets each including an ID and a data field for frames transmitted from a door open/close sensor ECU.

[Fig. 9] Fig. 9 is a diagram illustrating a configuration of a gateway according to the first embodiment.

[Fig. 10] Fig. 10 is a diagram illustrating an example of vehicle identification information held by a gateway according to the first embodiment.

[Fig. 11] Fig. 11 is a diagram illustrating an example of a transfer rule used by a gateway according to the first embodiment.

[Fig. 12] Fig. 12 is a diagram illustrating a configuration of a server according to the first embodiment.

[Fig. 13] Fig. 13 is a diagram illustrating an example of a detection window size identification table stored in a server according to the first embodiment.

[Fig. 14] Fig. 14 is a diagram illustrating an example of a frame transmission process sequence performed in an ECU.

[Fig. 15] Fig. 15 is a diagram illustrating an example of a frame transfer process sequence performed in a gateway according to the first embodiment.

[Fig. 16] Fig. 16 is a diagram illustrating an example of a detection window size determination sequence performed in a gateway and a server according to the first embodiment.

[Fig. 17] Fig. 17 is a diagram illustrating an example of a learning process sequence performed in a gateway and a server according to the first embodiment.

[Fig. 18] Fig. 18 is a diagram for illustrating a detection window used by a gateway according to the first embodiment.

[Fig. 19] Fig. 19 is a diagram illustrating an example of a model update process sequence performed in a gateway and a server according to the first embodiment.

[Fig. 20] Fig. 20 is a diagram illustrating an example of an abnormality detection process sequence performed in a gateway and a server according to the first embodiment.

[Fig. 21] Fig. 21 a diagram illustrating a configuration of an on-board network system in a vehicle according to a second embodiment.

[Fig. 22] Fig. 22 is a diagram illustrating a configuration of a gateway according to the second embodiment.

[Fig. 23] Fig. 23 is a diagram illustrating an example of a detection window size determination sequence performed in a gateway according to the second embodiment.

[Fig. 24] Fig. 24 is a diagram illustrating an example of a learning process sequence performed in a gateway according to the second embodiment.

[Fig. 25] Fig. 25 is a diagram illustrating an example of an abnormality detection process sequence performed in a gateway according to the second embodiment.

[Fig. 26] Fig. 26 is a diagram illustrating an example of a detection window according to a modification of an embodiment.


Description of Embodiments


(Underlying Knowledge Forming Basis of the Present Disclosure)



[0014] When an attack frame (message) is transmitted by an attacker to a bus of an on-board network, if this transmission of the attack frame leads to a change such that the number of frames received from the bus within a unit time becomes different from a criterion (model) indicating a frequency of occurrence of frames within this unit time in a normal state, it is possible to detect an abnormality. This is because the frequency of occurrence of frames on the bus per unit time in the normal state is limited by a configuration and/or specifications of the on-board network system (a configuration and/or specifications of ECUs connected via the bus). Note that the abnormality detection accuracy depends on whether the unit time is proper or not. Thus, an idea has been obtained as to an abnormality detection method in which, in an on-board network system of a vehicle, a unit time is determined (selected) to be, for example, 10 milliseconds from many time periods, and an abnormality is detected using the determined unit time. The on-board network system may be different in configuration, specification, or the like, for example, for each vehicle or each vehicle type, and thus, in the on-board network system of the vehicle, the unit time may be determined, by way of example, based on the vehicle identification information identifying the vehicle, the vehicle type, or the like. A wide variety of new attack methods may appear, and thus the optimum unit time for properly distinguishing between an attacked state and a normal state can be different with time. Therefore, it may be useful to employ a method in which the unit time for detecting an abnormality in the on-board network system of the vehicle is first determined and then an abnormality detection is performed. For example, it is useful to determine the unit time used to detect an abnormality based on a result of latest analysis of information on frames accumulated from a plurality of vehicles of the same type.

[0015] In an aspect, the present disclosure provides an abnormality detection method for detecting an abnormality in an on-board network system, the on-board network system including a plurality of electronic control units that transmit and receive messages via a bus in a vehicle according to a CAN (Controller Area Network) protocol, the abnormality detection method including determining a unit time, performing an operation process using feature information based on the number of messages received via the bus within the determined unit time and using a particular model indicating a criterion in terms of a message occurrence frequency and making a judgment as to an abnormality according to a result of the operation process. In this aspect, if an attacker transmits an attack frame (message) to the bus, this can cause the number of messages appearing per unit time to be different from the criterion (for example, 10 ms or the like) determined in the on-board network system, and thus it is possible to properly detect an abnormality.

[0016] For example, the message may include a message ID indicating a message type, and the abnormality detection method may include the steps of performing the determination of the unit time, identifying, as the feature information, a feature vector including components assigned to the respective message IDs and respectively indicating numbers of messages of the assigned message IDs received from the bus within the unit time determined in the determining step, and performing the judging according to a result of the operation process performed using the particular model and the feature information identified in the identifying step. Thus, the feature vector is determined based on the number received messages such that the feature vector properly indicates the frequencies of occurrence of messages for the respective message types, which makes it possible to properly detect an abnormality.

[0017] For example, in the determining step, the unit time may be determined based on the vehicle identification information for identifying the vehicle. This makes it possible to detect abnormalities with high accuracy depending on the on-board network system identified by the vehicle identification information.

[0018] For example, the vehicle identification information may indicate a manufacturer of the vehicle. In this aspect, it is possible to determine the unit time used in detecting an abnormality depending on the feature of the on-board network of each vehicle manufacturer, and thus it becomes possible to detect an abnormality with high accuracy.

[0019] For example, the vehicle identification information may indicate a type of the vehicle. This makes it possible to determine the unit time used in detecting an abnormality depending on the feature of the on-board network of each vehicle type, and thus it becomes possible to detect an abnormality with high accuracy.

[0020] For example, the vehicle identification information may be information that distinguishes the vehicle from the other vehicles. This makes it possible to detect an abnormality in a manner adapted to the feature of the on-board network system of each vehicle.

[0021] For example, in the determining step, the unit time may be determined to be equal to a transmission period of one type of message which is the shortest among a plurality of different types of messages to be transmitted in a normal state via an in-vehicle bus in an on-board network system of a vehicle included in a set of vehicles identified by the vehicle identification information. This makes it possible to properly detect an abnormality with high accuracy.

[0022] For example, in the judging step, the operation process may be performed using the particular model corresponding to the vehicle identification information. In this aspect, the abnormality detection is performed based on the particular model corresponding to the unit time determined in the on-board network system and the number of messages received in the on-board network within the determined unit time, and thus it becomes possible to properly detect an abnormality.

[0023]  For example, in the identifying step, the feature information may be identified based on the number of messages received from the bus within the unit time determined in the determining step wherein the identifying is performed sequentially every period with a length equal to the determined unit time, and in the judging step, the operation process may be performed on each piece of feature information sequentially identified in the identifying step, the operation process being performed using the feature information and the particular model, and wherein the abnormality detection method may further include the step of sequentially updating the particular model based on the plurality of pieces of feature information sequentially identified in the identifying. In this aspect, the particular model used in the abnormality detection is sequentially updated, and thus, for example, it becomes possible to properly perform the abnormality detection adaptively depending on a latest state of the on-board network (for example, a latest state in which the vehicle is used).

[0024] For example, in the determining step, the unit time may be determined in the vehicle based on information defined when the vehicle was produced, and in the identifying step, the feature information may be identified in the vehicle. In this aspect, based on information (for example, a chassis number or the like) defined when the vehicle was produced, it becomes possible to determine the unit time serving as a basis for generating feature information used in the vehicle in the abnormality detection, and thus it becomes possible to perform the abnormality detection properly depending on the vehicle.

[0025] For example, in the determining step, the unit time may be determined in the vehicle when an engine or an accessory of the vehicle is turned on, and in the identifying step, the feature information may be identified in the vehicle. In this aspect, the unit time serving as the basis in generating feature information used in the abnormality detection in the vehicle can be determined when use of the vehicle is started (when driving is started or the like), and thus, for example, it becomes possible to properly detect an abnormality adaptively depending on a recent situation.

[0026] For example, in the determining step, the unit time may be determined every predefined time period, in the identifying step, the feature information may be identified based on the number of messages received from the bus within the unit time determined most recently in the determining step, the identifying being performed sequentially every period with a length equal to the unit time determined most recently, and in the judging step, the operation process may be performed on each piece of feature information sequentially identified in the identifying step, the operation process being performed using the feature information and the particular model. In this aspect, the unit time serving as the basis in generating feature information used in the abnormality detection in the vehicle is determined every predefined time, and thus, for example, it becomes possible to properly detect an abnormality adaptively depending on a recent situation.

[0027] For example, the message may include a message ID indicating a message type, and the feature information may indicate the total number of messages of all message IDs received from the bus within the determined unit time. Not distinguishing between IDs makes it possible to efficiently perform the abnormality detection.

[0028] In as aspect, the present disclosure provides an abnormality detection apparatus that detects an abnormality, the abnormality detection apparatus being connected to a bus in an on-board network system, the on-board network system including a plurality of electronic control units that transmit and receive messages via the bus in a vehicle according to a CAN (Controller Area Network) protocol, the abnormality detection apparatus including a receiver that receives a message from the bus, a determiner that determines a unit time, an identifier that identifies feature information based on the number of messages received by the receiver within the unit time determined by the determiner, and a judger that judges whether there is an abnormality depending on a result of an operation process performed using the feature information identified by the identifier and a particular model indicating a criterion in terms of a message occurrence frequency. The operation process may be performed by the abnormality detection apparatus or an external apparatus (server), and, depending on a result of the operation process, the judgment may be performed by the judger of the abnormality detection apparatus. In a case where the operation process is performed by a server, for example, the abnormality detection apparatus may transmit feature information identified by the identifier to the server, and may receive a result of the operation process from the server. When an attack frame (message) is transmitted by an attacker to the bus, a difference occurs, from the criterion, in the number of messages appearing per unit time (for example, 10 ms) determined by the abnormality detection apparatus, and thus it is possible to properly detect an abnormality.

[0029] In an aspect, the present disclosure provides an abnormality detection system including a vehicle and a server, the vehicle including an on-board network system and an abnormality detection apparatus, the on-board network system including a plurality of electronic control units that transmit and receive messages via a bus in the vehicle according to a CAN (Controller Area Network) protocol, the abnormality detection apparatus being connected to the bus, the abnormality detection apparatus including a receiver that receives a message from the bus, a determiner that transmits vehicle identification information for identifying the vehicle to the server and determines a unit time based on a response returned from the server, an identifier that identifies feature information based on the number of messages received by the receiver within the unit time determined by the determiner, and a judger that judges whether there is an abnormality depending on a result of an operation process performed using the feature information identified by the identifier and a particular model indicating a criterion in terms of a message occurrence frequency, the server including a communicator that receives vehicle identification information from the vehicle and transmits, to the vehicle, information indicating a unit time identified based on the vehicle identification information. For example, the judger may transmit the feature information identified by the identifier to the server, and may make a judgment based on a response (for example, information indicating whether the state is abnormal or not) returned from the server as to whether the state is abnormal or not. In this case, for example, the server may perform an operation process associated with the particular model using the received feature information, and may transmit information based on a result of the operation process, as a response to the received feature information, to the vehicle. This makes it possible to determine the unit time depending on the vehicle identification information of the vehicle, and thus it becomes possible to properly determine whether there is an abnormality in the on-board network of the vehicle.

[0030] For example, the server may further include a learner that acquires particular information based on the number of messages received from a bus in an on-board network system of one or more vehicles in a set of vehicles identified by the vehicle identification information, and updates, based on the particular information, a criterion model indicating a criterion in terms of message occurrence frequency, the communicator may transmit, to the vehicle, information indicating the criterion model updated by the learner, the abnormality detection apparatus may update the particular model based on the information indicating the criterion model received from the server, and the judger may perform an operation process using the feature information and the updated particular model and may perform the judgment as to whether the state is abnormal or not. Thus, in the server, the criterion model is updated via learning using particular information (for example, information similar to the feature information) based on the number of messages received in an on-board network in a set of vehicles (for example, vehicles of the same type) identified by the vehicle identification information. In the vehicle abnormality detection apparatus, it is possible to update the particular model based on the criterion model, for example, such that the particular model becomes equal to the criterion model thereby making it possible to use the particular model in judging whether the state is abnormal or not. Therefore, it becomes possible for the abnormality detection apparatus to properly execute detecting (judging) of an abnormality in a manner adapted to a vehicle (a vehicle identified by the vehicle identification information) in which the abnormality detection apparatus is installed.

[0031] General or specific embodiments may be implemented by a system, a method, an integrated circuit, a computer program, a computer-readable storage medium such as a CD-ROM, or any selective combination of a system, a method, an integrated-circuit, a computer program, and a storage medium.

[0032] An abnormality detection system, an abnormality detection apparatus, and the like using the abnormality detection method according to the embodiment are described below with reference to drawings. Note that each embodiment described below is for illustrating a specific example of an implementation of the present disclosure. In the following embodiments, values, constituent elements, locations of elements, manners of connecting elements, steps, the order of steps, and the like are described by way of example but not limitation. Among constituent elements described in the following embodiments, those constituent elements that are not described in independent claims are optional. Note that each drawing is a schematic diagram, which does not necessarily provide a strict description.

(First Embodiment)



[0033] An embodiment of the present disclosure is described below with reference to drawings for a case in which in an abnormality detection system, abnormality detection apparatus for detecting an abnormality in an on-board network in a vehicle is configured to determine, in cooperation with a server outside the vehicle, a detection window size (a unit time) used in detecting the abnormality. In this abnormality detection system, the abnormality detection apparatus sends, to a server, vehicle identification information on the vehicle in which the abnormality detection apparatus is installed, and determines the detection window size used in detecting an abnormality based on a response returned from the server.

[1.1 Total configuration of abnormality detection system 10]



[0034] Fig. 1 is a diagram illustrating a total configuration of an abnormality detection system 10 according to a first embodiment.

[0035] The abnormality detection system 10 includes a vehicle including an on-board network system, and a server 400 capable of mutually communicating with the vehicle. The abnormality detection system 10 may include a plurality of vehicles capable of communicating with the server 400. However, in Fig. 1, for convenience, only one vehicle is shown.

[0036] The on-board network system in the vehicle illustrated in Fig. 1 is an example of a network communication system which performs communication according to the CAN protocol, and the on-board network system includes various kinds of devices including a control apparatus, a sensor, an actuator, a user interface apparatus, and the like. This on-board network system includes an ECU 100a (an engine ECU), an ECU 100b (a brake ECU), an ECU 100c (a door open/close sensor ECU), and an ECU 100d (a door open/close sensor ECU), which are respectively connected to various kinds of devices installed in the vehicle, and buss 200a and 200b, and a gateway 300 (an example of the abnormality detection apparatus). Note that the on-board network system may further include other ECUs in addition to the gateway 300 and the ECUs 100a to 100d. However, for convenience, the present description focuses on the gateway 300 and the ECUs 100a to 100d. Each ECU is an apparatus which may include, for example, a digital circuit such as a processor (a microprocessor), a memory, and/or the like, an analog circuit, a communication circuit, and/or the like. The memory may be a ROM, a RAM, or the like and may store a control program (a computer program functioning as software) executed by the processor. For example, the processor operates in accordance with the control program (the computer program) such that the ECU realizes various functions. Note that, to realize a particular function, the computer program includes a plurality of instruction codes indicating instructions issued to the processor. Each ECU is capable of receiving and transmitting frames via the buss 200a and 200b in the vehicle according to the CAN protocol.

[0037] The ECUs 100a to 100d are respectively connected to devices such as an engine 101, a brake 102, a door open/close sensor 103, and the ECUs 100a to 100d acquires states of the respective devices and periodically transmit frames (data frames) indicating the states over the on-board network including the bus 200a, the bus 200b, and the like.

[0038] The gateway 300 is a kind of an ECU, which is connected to the bus 200a, to which the ECU 100a and the ECU 100b are connected, and the bus 200b, to which the ECU 100c and the ECU 100d are connected, and which has a capability of transferring a frame received from one of the buses to the other one of the buses. Furthermore, the gateway 300 functions as an abnormality detection apparatus having a capability of detecting an abnormality by judging whether a frame received from a bus is abnormal or note (for example, by judging whether an attack frame is transmitted over a bus in an abnormal state), and notifying the server 400 of a detection result (an abnormality detection result). The abnormality detection by the gateway 300 functioning as the abnormality detection apparatus is performed in general such that in each detection window which is a period having a time length corresponding to a detection window size, the judgment as to the abnormality is made based on a result of an operation process such as a process of comparing feature information based on the number of data frames (messages) received within the detection window from the bus 200a or 200b in the on-board network with the particular model indicating the criterion in terms of the message occurrence frequency. The gateway 300 also has a capability of determining information (for example, parameters in terms of the detection window size, the particular model, or the like) for use in detecting abnormality (for making a judgment as to abnormality) via communication with the server 400 via the network 40.

[0039] The server 400 is a computer disposed outside the vehicle, and has a capability of communicating with the gateway 300 of each vehicle via the network 40 and returning, as a response, information for use in abnormality detection (information indicating the detection window size or the like) based on the received vehicle identification information to the gateway 300. The server 400 also has a capability of storing the abnormality detection result received from the gateway 300. The server 400 may have a capability of communicating with each gateway 300 in the vehicle and accumulating and analyzing information on frames received by on-board network in each vehicle. Note that the communication via the network 40 may be performed wirelessly or via a cable according to any communication protocol.

[1.2 Data frame format]



[0040] The data frame which is one type of frames used in networks according to the CAN protocol is described below.

[0041] Fig. 2 is a diagram illustrating a data frame format according to the CAN protocol. In Fig. 2, the data frame shown is a data frame according to a standard ID format defined in the CAN protocol. The data frame includes fields such as SOF (Start Of Frame), an ID field, RTR (Remote Transmission Request), IDE (Identifier Extension), a reserved bit "r", DLC (Data Length Code), a data field, a CRC (Cyclic Redundancy Check) sequence, a CRC delimiter "DEL", an ACK (Acknowledgement) slot, an ACK delimiter "DEL", and EOF (End Of Frame).

[0042] SOF includes a one dominant bit. When the bus is in an idle state, the SOF is in a recessive state. When transmission is started, the SOF is set to dominant thereby providing a notification of start of a frame.

[0043] The ID field is a field including 11 bits and storing an ID (a message ID) having a value indicating a data type. When a plurality of nodes start transmission at the same time, communication arbitration is performed according to ID fields such that a frame having a smaller ID value is given a higher priority.

[0044] RTR has a value identifying a data frame and a remote frame. In the case of a data frame, RTR has a 1 dominant bit.

[0045] IDE and "r" each have one dominant bit.

[0046] DLC includes 4 bits indicating a length of the data field. Note that IDE, "r", and DLC are collectively called a control field.

[0047] The data field has a value including up to 64 bits indicating a content of data to be transmitted. The length is allowed to be adjusted in units of 8 bits. The specification of the data to be transmitted is not defined in the CAN protocol, but defined in the on-board network system. Therefore, the specification depends on a vehicle type, a manufacturer (a maker), or the like.

[0048] The CRC sequence includes 15 bits. The value thereof is calculated based on the transmission values of the SOF, the ID field, the control field, and the data field.

[0049] The CRC delimiter is a delimiter including one recessive bit indicating an end of the CRC sequence. Note that the CRC sequence and the CRC delimiter are collectively called a CRC field.

[0050] The ACK slot includes 1 bit. When a transmission node performs transmission, the ACK slot is set to recessive. When a reception node normally receives fields until the end of the CRC sequence, the reception node transmits a dominant ACK slot. Dominant bits are higher in priority than recessive bits. Therefore, when a dominant ACK slot is obtained after the transmission, the transmission node recognizes that the fields have been successfully received by some reception node.

[0051] The ACK delimiter is a delimiter including one recessive bit indicating an end of ACK.

[0052] EOF includes seven recessive bits to indicate an end of the data frame.

[1.3 Configuration of ECU 100a]



[0053] Fig. 3 is a configuration diagram of the ECU 100a. The ECU 100a includes a frame transmission/reception unit 110, a frame interpreter 120, an acceptance ID judgment unit 130, an acceptance ID list storage 140, a frame processor 150, a data acquisition unit 160, and a frame generator 170. Each function of each of these constituent elements is realized, for example, by a communication circuit in the ECU 100a, a processor, or a digital circuit that executes a control program stored in a memory, or the like. Note that the ECUs 100b to 100d are each have a similar configuration to that of the ECU 100a.

[0054] The frame transmission/reception unit 110 transmits and receives frames to or from the bus 200a according to the CAN protocol. A frame is received from the bus 200a on a bit-by-bit basis and transferred to the frame interpreter 120. Furthermore, a content of the frame notified from the frame generator is transmitted to the bus 200a.

[0055] The frame interpreter 120 receives values of the frame from the frame transmission/reception unit 110 and interprets the values such that the values are mapped to fields according to the frame format defined in the CAN protocol. A value determined to be mapped to an ID field is transferred to the acceptance ID judgment unit 130. According to a judgment result notified from the acceptance ID judgment unit 130, the frame interpreter 120 determines whether the value of the ID field and data fields appearing following the ID field are to be transferred to the frame processor 150 or further receiving of frames after the judgment is stopped (that is, the further interpretation of frames is stopped). In a case where the judgment of a frame by the frame interpreter 120 is that the frame is not according to the CAN protocol, the frame interpreter 120 notifies the frame generator 170 that an error frame is to be transmitted. In a case where an error frame is received, that is, in a case where the frame interpreter 120 interprets, based on a value of the received frame, that the received frame is an error frame, the frame interpreter 120 discards following frames, that is the frame interpreter 120 stops the interpreting of frames.

[0056] The acceptance ID judgment unit 130 receives the value of the ID field notified from the frame interpreter 120 and determines, according to the list of message IDs stored in the acceptance ID list storage 140, whether to receive fields following the ID field in the frame. A judgment result is notified from the acceptance ID judgment unit 130 to the frame interpreter 120.

[0057] The acceptance ID list storage 140 stores an acceptance ID list that is a list of message IDs to be received by the ECU 100a. Fig. 4 illustrates an example of an acceptance ID list.

[0058] The frame processor 150 performs processes that are different depending on ECUs according to data of a received frame. For example, the ECU 100a connected to the engine 101 has a function of generating an alarm sound when the vehicle runs at a speed higher than 30 km/hour with a door being in an open state. The ECU 100a includes a speaker or the like for generating, for example, an alarm sound. The frame processor 150 of the ECU 100a manages data (for example, information indicating the door state) received another ECU, and performs a process of generating an alarm sound under a certain condition according to the speed per hour acquired from the engine 101. Note that the frame processor 150 may perform a process different from the example described above on data of a frame.

[0059] The data acquisition unit 160 acquires data indicating a state of a device connected to an ECU and data indicating a state of a sensor or the like, and supplies the acquired data to the frame generator 170.

[0060] The frame generator 170 constructs an error frame according to an error frame transmission command given by the frame interpreter 120, and supplies the error frame to the frame transmission/reception unit 110 thereby controlling the frame transmission/reception unit 110 to transmit the error frame. The frame generator 170 also constructs a frame (data frame) such that a predetermined message ID is attached to a data value notified from the data acquisition unit 160, and supplies the resultant frame to the frame transmission/reception unit 110. The content of the frame transmitted by each of the ECUs 100a to 100d will be described later with reference to Fig. 5 to Fig. 8.

[1.4 Example of acceptance ID list]



[0061] Fig. 4 is a diagram illustrating an example of an acceptance ID list stored in each of the ECUs 100a to 100d. The acceptance ID list illustrated by way of example in Fig. 4 is used to selectively receive and process a frame (a message) including a message ID whose value is one of "1", "2", "3", and "4". For example, in a case where the acceptance ID list illustrated in Fig. 4 is stored in the acceptance ID list storage 140 of the ECU 100a, when a frame has a message ID different from any one of "1", "2", "3", and "4", the frame interpreter 120 stops the frame interpretation following the ID field.

[1.5 Example of frame transmitted by engine ECU 100a]



[0062] Fig. 5 is a diagram illustrating examples of sets each including an ID (a message ID) and a data field (data) for frames transmitted from the ECU 100a connected to the engine 101. Each frame transmitted by the ECU 100a is assigned "1" as its message ID. The data indicates a speed per hour (km/hour) which is allowed to take a value in a range from a minimum value of 0 (km/hour) to a maximum value of 180 (km/hour). The data length thereof is 1 byte. In Fig. 5, message IDs and data corresponding to frames sequentially transmitted from the ECU 100a are described row by row from the top row toward lower rows. In this example, the data indicates that the speed per hour is increased in steps of 1 km/hour starting from 0 km/hour.

[1.6 Example of frame transmitted by brake ECU 100b]



[0063] Fig. 6 is a diagram illustrating examples of sets each including an ID (a message ID) and a data field (data) for frames transmitted from the ECU 100b connected to the brake 102. Each frame transmitted by the ECU 100b is assigned "2" as its message ID. The data represents a degree to which brake is applied in percentage(%), and the data length thereof is 1 byte. When the brake is not applied at all, the value in percentage is 0(%), while when the brake is applied fully, the value in percentage is 100(%). In Fig. 6, message IDs and data of frames sequentially transmitted from the ECU 100b are described row by row from the top row toward lower rows. In this example, the data indicates that the brake is reduced gradually starting from 100%.

[1.7 Example of frame transmitted from door open/close sensor ECU 100c]



[0064] Fig. 7 is a diagram illustrating examples of sets each including an ID (a message ID) and a data field (data) for frames transmitted from the ECU 100d connected to the door open/close sensor 103. Each frame transmitted by the ECU 100c is assigned "3" as its message ID. The data represents an open/close state of a door. The data length thereof is 1 byte. When the door is in an open state, the data has a value of "1", while when the door is in a closed state, the data has a value of "0". In Fig. 7, message IDs and data of frames sequentially transmitted from the ECU 100c are described row by row from the top row toward lower rows. In this example, data indicates that the open/close state of the door gradually changes from the open state to the closed state.

[1.8 Example of frame transmitted from door open/close sensor ECU 100d]



[0065] Fig. 8 is a diagram illustrating examples of sets each including an ID (a message ID) and a data field (data) for frames transmitted from the ECU 100d connected to the door open/close sensor 104. Each frame transmitted by the ECU 100d is assigned "4" as its message ID. The data represents an open/close state of a window in percentage (%), and the data length thereof is 1 byte. When the window is in a completely closed state, the value in percentage is 0(%), while when the window is in a completely open state, the value in percentage is 100(%). In Fig. 8, message IDs and data of frames sequentially transmitted from the ECU 100d described row by row from the top row toward lower rows. In this example, data indicates that the open/close state of the window gradually changes from the closed state to the open state.

[1.9 Configuration of gateway 300]



[0066] Fig. 9 is a diagram illustrating a configuration of the gateway 300. The gateway 300 includes a frame transmission/reception unit 310, a frame interpreter 320, an acceptance ID judgment unit 330, an acceptance ID list storage 340, a conversion processing unit 350, an external communication unit 360, a vehicle identification information storage 361, an abnormality detection processor 370, a model storage 371, a transfer processor 380, a transfer rule storage 381, and a frame generator 390. Each function of each of these constituent elements is realized, for example, by a communication circuit in the gateway 300, a processor, or a digital circuit that executes a control program stored in a memory, or the like.

[0067] The frame transmission/reception unit 310 transmits and receives, according to the CAN protocol, frames to and from the bus 200a and the bus 200b respectively. The frame transmission/reception unit 310 functions as a receiver that receives a frame from the bus on a bit-by-bit basis, and transfers the received frame to the frame interpreter 320. Furthermore, based on a frame and bus information indicating a destination bus received from the frame generator 390, the frame transmission/reception unit 310 transmits a content of the frame to the bus 200a or the bus 200b on a bit-by-bit basis.

[0068] The frame interpreter 320 receives values of the frame from the frame transmission/reception unit 310 and interprets the values such that the values are mapped to fields according to the frame format defined in the CAN protocol. A value determined to be mapped to an ID field is transferred to the acceptance ID judgment unit 330. According to a judgment result notified from the acceptance ID judgment unit 330, the frame interpreter 320 determines whether the value of the ID field and the data field (data) following the ID field are to be transferred to the transfer processor 380, or receiving of frames is to be stopped after the judgment result is received. As for a value determined to be mapped to the ID field, the frame interpreter 320 notifies the conversion processing unit 350 of the value of the ID field. In a case where a frame is judged, by the frame interpreter 320, as a frame that is not according to the CAN protocol, the frame interpreter 320 notifies the frame generator 390 that an error frame is to be transmitted. In a case where the frame interpreter 320 receives an error frame, that is, in a case where it is determined, from the received value of the frame, that the received frame is an error frame, the frame interpreter 320 discards the frame thereafter, that is, the frame interpreter 320 stops the interpretation of the frame.

[0069] The acceptance ID judgment unit 330 receives the value of the ID field sent from the frame interpreter 320 and judges, according to a list of message IDs stored in the acceptance ID list storage 340, whether to receive fields following the ID field in the frame. The acceptance ID judgment unit 330 notifies the frame interpreter 320 of the determination result.

[0070] The acceptance ID list storage 340 stores an acceptance ID list (see Fig. 4) which is a list of IDs (message IDs) that the gateway 300 receives.

[0071] The conversion processing unit 350 determines the detection window size based on the information given from the server 400 in terms of the detection window size, and the processing unit 350 holds the determined detection window size. That is, the conversion processing unit 350 functions as a determiner that determines the detection window size. Based on the value of the ID field notified from the frame interpreter 320, the conversion processing unit 350 makes a conversion such that a set of frames sequentially received from the bus 200a or 200b (a set of values of the ID field sequentially notified) in each detection window with a time length corresponding to the detection window size is converted to feature information indicating the number of frames received in the detection window individually for each ID (for each message ID) (that is, the count values obtained by counting the frames received in the detection window with the detection window size individually for the respective IDs), and processing unit 350 sends the feature information to the external communication unit 360. That is, the conversion processing unit 350 also functions as an identifier that identifies feature information. The conversion processing unit 350 sequentially notifies the abnormality detection processor 370 of the feature information based on the number of frames sequentially received within the detection window with the detection window size from the buses 200a and 200b.

[0072] The external communication unit 360 transmits vehicle identification information held by the vehicle identification information storage 361 to the server 400 via the network 40, and the external communication unit 360 sends, to the conversion processing unit 350, information indicating the detection window size received, as a response, from the server 400. The external communication unit 360 also notifies (sends the feature information to) the server 400 of the feature information notified from the conversion processing unit 350. Furthermore, the external communication unit 360 provides model information (information representing a criterion model indicating a criterion in terms of an occurrence frequency of data frames) received from the server 400 to the abnormality detection processor 370. The external communication unit 360 notifies (transmits the result of the abnormality detection to) the server 400 of the result of the abnormality detection received from the abnormality detection processor 370.

[0073] The vehicle identification information storage 361 stores vehicle identification information for identifying vehicles. Fig. 10 illustrates an example of vehicle identification information.

[0074] The abnormality detection processor 370 acquires, via the external communication unit 360, the model information transmitted from the server 400, and, based on the model information, the abnormality detection processor 370 updates a particular model (a model indicating a criterion in terms of the frequency of occurrence of data frames) stored in the model storage 371. For example, the abnormality detection processor 370 may update the particular model so as to become identical to the criterion model indicated by the model information. The abnormality detection processor 370 also functions as a judger that receives feature information converted by the conversion processing unit 350 based on a value of the ID field notified from the frame interpreter 320, performs an operation process using the feature information and the particular model stored in the model storage 371, and performs the judgment as to whether the state is abnormal or not based on a result of the operation process. That is, the abnormality detection processor 370 judges whether the feature information associated with the set of frames received from the bus satisfies the criterion indicated by the particular model by performing the operation process using the feature information and the particular model. In this judgment, when the number of data frames received in the detection window size reflected in feature information, counted individually for each ID, is consistent with the criterion (for example, a criterion in terms of the frequency of occurrence of data frames in the normal state) indicated by the particular model, it is judged that the state is normal. However, when the criterion is not satisfied (that is, when the number is deviated from the criterion), it is judged that the state is abnormal. The operation process is defined to achieve the judgment in the above-described manner. The operation process is, for example, a combination of one or more processes including a comparison, an arithmetic operation, a logical operation, a conditional judgment, and the like between the particular model and the feature information. The abnormality detection processor 370 sends a result of the judgment made by the operation process as to whether the state is abnormal or not (that is, an abnormality detection result) to the external communication unit 360.

[0075] The model storage 371 stores the particular model notified from the abnormality detection processor 370.

[0076] The transfer processor 380 determines the bus to be used in transferring (the transfer destination bus) according to the transfer rule stored in the transfer rule storage 381 depending on the ID of the received frame (the message ID), and the transfer processor 380 sends bus information indicating the bus to be used in the transfer, the message ID notified from the frame interpreter 320, and data to the frame generator 390.

[0077] The transfer rule storage 381 stores the transfer rule that is information indicating the rule of transferring frames for each bus. Fig. 11 illustrates an example of a transfer rule.

[0078] The frame generator 390 configures an error frame according to an instruction indicated, in a notification received from the frame interpreter 320, that an error frame is to be transmitted, and the frame generator 390 sends the error frame to the frame transmission/reception unit 310 thereby controlling the frame transmission/reception unit 310 to transmit the error frame. The frame generator 390 also configures a frame using data and a message ID notified from the transfer processor 380, and sends the resultant frame and bus information to the frame transmission/reception unit 310.

[1.10 Vehicle identification information]



[0079] Fig. 10 illustrates an example of vehicle identification information held by a gateway 300. The vehicle identification information is information for identifying the vehicle. Fig. 10 illustrates an example of vehicle identification information indicating a car maker (vehicle manufacturer), a vehicle type, and a chassis number. In this example, for example, the chassis number is information (information identifying each vehicle) that distinguishes each vehicle from the other vehicles, and the chassis number includes a model (vehicle model) and a serial number. Note that vehicles that are the same in type have the same configuration of the on-board network, and have the same specifications in terms of the use of data frames (messages) (the specifications of the content of the data field for each message ID) transmitted over the CAN bus of the on-board network. For example, vehicles that are the same in type are the same in vehicle model. The vehicle identification information is not limited to this example, but the vehicle identification information may be, for example, vehicle identification number (VIN) or the like. For example, when vehicles have the same values from the beginning to a digit before the serial number in the vehicle identification number, these vehicles are the same in vehicle type. Note that the vehicle identification information does not necessarily need to be information that uniquely identifies a vehicle. For example, the vehicle identification information may be information indicating only the type of the vehicle, information indicating only the manufacturer of the vehicle, information indicating only the chassis number, or information which is a combination of one or more of pieces of information described above and another information.

[1.11 Transfer rule]



[0080] Fig. 11 illustrates an example of a transfer rule stored in the transfer rule storage 381 of the gateway 300.

[0081] The transfer rule indicates a correspondence between a transfer source bus and a transfer destination bus and an ID of a frame to be transferred (a message ID). In Fig. 11, "*" indicates that frame transfer is performed regardless of the message ID. In the example illustrated in Fig. 11, the rule is set such that a frame received from the bus 200a is transferred to the bus 200b regardless of the message ID. Furthermore, in this example, the rule is also set such that, of frames received from the bus 200b, only frames having a message ID of "3" are transferred to the bus 200a.

[1.12 Configuration of server 400]



[0082] The server 400 is a computer located outside the vehicle and capable of, for example, managing a plurality of vehicles. The server 400 includes a storage medium such as a memory, a hard disk, or the like, a processor, a communication circuit, and the like.

[0083] Fig. 12 is a diagram illustrating a configuration of the server 400. The server 400 includes, as illustrated in Fig. 12, a communicator 410, a data accumulation unit 420, a learner 430, a detection window size identification unit 440, a detection window size identification table storage 450, and an abnormality detection result storage 460. Each of these constituent elements is realized by a communication circuit in the server 400, a processor or the like that executes a control program stored in a memory, or the like.

[0084] The communicator 410 communicates with the gateway 300 of each vehicle via the network 40. Furthermore, the communicator 410 sequentially receives, from the gateway 300, feature information in which the counts per the detection window size for the respective IDs are reflected, and the communicator 410 accumulates the received feature information in the data accumulation unit 420 separately for the respective vehicles. Furthermore, the communicator 410 notifies (transmits model information to) the gateway 300 of model information indicating the criterion model notified from the learner 430. Furthermore, the communicator 410 notifies the detection window size identification unit 440 of the vehicle identification information notified from the gateway 300, and notifies (transmits information indicating the detection window size to) the gateway 300 of the detection window size notified from the detection window size identification unit 440. Furthermore, the communicator 410 controls the abnormality detection result storage 460 to store an abnormality detection result notified from the gateway 300.

[0085] The data accumulation unit 420 accumulates (stores) the feature information notified from the communicator 410 distinctively for each vehicle.

[0086] The learner 430 constructs the criterion model (the model indicating the criterion in terms of the frequency of occurrence of data frames appearing on a bus of an on-board network of a vehicle) for each vehicle based on the feature information associated with vehicle accumulated in the data accumulation unit 420, and the learner 430 stores the constructed criterion model. The learner 430 updates the criterion model, as required, based on the feature information. For example, the learner 430 sequentially updates the stored criterion models, for example, via machine learning based on feature information sequentially collected by the communicator 410 and the data accumulation unit 420.

[0087] The detection window size identification unit 440 refers to a detection window size identification table stored in the detection window size identification table storage 450, and identifies a detection window size depending on vehicle identification information notified from the communicator 410, and the detection window size identification unit 440 notifies the communicator 410 of information indicating the identified detection window size.

[0088] The detection window size identification table storage 450 stores the detection window size identification table used in identifying the detection window size depending on the vehicle identification information. Fig. 13 illustrates an example of a detection window size identification table.

[0089] The abnormality detection result storage 460 stores, as a log for each vehicle, the abnormality detection result notified from the communicator 410. Note that in a case where the server 400 manages a plurality of vehicles, for example, the information from each vehicle may be classified by the server 400 based on the vehicle identification information received from the vehicle, while the gateway 300 of the vehicle may, for example, attach all or part of the vehicle identification information to the feature information or the abnormality detection result transmitted by the gateway 300 to the server 400.

[1.13 Detection window size identification table]



[0090] Fig. 13 illustrates an example of a detection window size identification table stored in the server 400. The detection window size identification table illustrated in Fig. 13 is a table representing a correspondence between vehicle identification information and a detection window size. The vehicle identification information in the detection window size identification table illustrated by way of example in Fig. 13 includes, as in the example illustrated in Fig, 10, a car maker, a vehicle type, and a chassis number. The detection window size may be determined, for example, such that the detection window size is equal to a transmission period of a type of data frame whose transmission period is the shortest of a plurality of types of data frames (that is, a plurality of data frames with message IDs different from each other) to be transmitted in a normal state over a CAN bus in the on-board network system of each vehicle in a set of vehicles identified by the vehicle identification information. To determine the detection window size, information may be referred to as to specifications of the on-board network system or a result of analysis of current situations, in terms of normal state, of the on-board network system. For example, in a case where the vehicle identification information identifies not individual vehicles but only the vehicle type, the detection window size may be determined so as to be equal to the shortest one of the transmission periods of frames of a plurality of IDs to be transmitted in a normal state in the on-board network system of each vehicle of the type of interest. The detection window size in the detection window size identification table may be determined in other ways. In any case, it is useful to determine the detection window size such that it is possible to properly distinguish, by the abnormality detection apparatus (the gateway 300) of a vehicle, between a normal state and a state in which an attack occurs.

[1.14 Frame transmission process by ECU 100a]



[0091] Fig. 14 illustrates an example of a frame transmission process sequence performed by the ECU 100a. Referring to Fig. 14, the frame transmission process by the ECU 100a is described below.

[0092] The ECU 100a acquires, by the data acquisition unit 160, data from a sensor (in terms of, for example, a vehicle speed obtained by measuring, for example, a parameter of the engine 101 by the sensor) (step S1101).

[0093] Next, based on the data acquired from the sensor, the ECU 100a generates, by the frame generator 170, a frame (a data frame) to be transmitted (step S1102).

[0094] Next, the ECU 100a transmits (broadcasts) the generated frame to the bus 200a (step S1103). The process from step S1101 to step S1103 is generally repeated periodically at fixed intervals.

[0095] Also in the ECUs 100b to 100d, the frame transmission process may be performed according to a procedure similar to that by the ECU 100a. However, the transmission repetition period may be different between the respective ECUs.

[1.15 Frame transfer process by gateway 300]



[0096] Fig. 15 illustrates an example of a frame transfer process sequence performed in the gateway 300. Referring to Fig. 15, the frame transfer process by the gateway 300 is described below. The gateway 300 performs the frame transfer process each time a frame (a data frame) is received from either one of the bus 200a and the bus 200b. In the following description, it is assumed by way of example that the gateway 300 transfers a frame received from the bus 200a to the bus 200b.

[0097] The gateway 300 receives a frame transmitted (broadcast) to the bus 200a (step S1201).

[0098]  Next, the gateway 300 confirms the transfer rule (see Fig. 11) (step S1202).

[0099] In a case where the judgment by the gateway 300 based on the transfer rule is that the received frame is a frame to be transferred, the gateway 300 generates a frame to be transferred based on the content of the received frame (step S1203).

[0100] Next, the gateway 300 transmits (broadcasts) the frame to be transferred to the bus 200b, and ends the frame transfer process (step S1204). On the other hand, in a case where the judgment based on the transfer rule confirmed in step S1202 is that the received frame is not a frame to be transferred, the gateway 300 ends the frame transfer process without transferring the frame.

[1.16 Detection window size determination sequence]



[0101] Fig. 16 illustrates an example of a detection window size determination sequence performed, in cooperation, by the gateway 300 and the server 400. Referring to Fig. 16, the detection window size determination sequence is described below.

[0102] The gateway 300 acquires vehicle identification information (step S1301). The acquisition of the vehicle identification information by the gateway 300 is from the vehicle identification information storage 361. The vehicle identification information storage 361 may store the vehicle identification information, for example, when the gateway 300 is installed in the vehicle (for example, when the vehicle is produced), or the gateway 300 may receive vehicle identification information of an ECU from this ECU in a vehicle including prestored vehicle identification information and the vehicle identification information storage 361 may store the received vehicle identification information.

[0103] The gateway 300 transmits the vehicle identification information acquired in step S1301 to the server 400 (step S1302a). Thus, the server 400 receives the vehicle identification information (step S1302b). Note that the transmission of the vehicle identification information from the gateway 300 to the server 400 is performed, for example, when the gateway 300 is installed in the vehicle (for example, when the vehicle is produced). The transmission of the vehicle identification information may be performed at another time or may be performed at one of a plurality of times. An example of one of timings of the transmission (the timing of transmitting the vehicle identification information by the gateway 300 to the server 400) is each time the vehicle is used such as driving of the vehicle is started (for example, each time the engine of the vehicle is started or each time an accessory is turned on (ACC-ON), or the like), each time a particular time elapses (for example, one every day), or the like. In synchronization with the timing of transmitting the vehicle identification information from the gateway 300 to the server 400, the whole of the detection window size determination sequence illustrated in Fig. 16 may be executed.

[0104] In the server 400, the detection window size identification unit 440 identifies the detection window size according to the vehicle identification information received in step S1302b (step S1303), and the detection window size identification unit 440 transmits, as a response to the vehicle identification information, information (detection window size information) indicating the identified detection window size to the gateway 300 (step S1304a). Thus, the gateway 300 receives the detection window size information (step S1304b).

[0105] In the gateway 300, the conversion processing unit 350 determines the detection window size according to the received detection window size information, and stores the detection window size (step S1305).

[1.17 Learning process sequence]



[0106] Fig. 17 illustrates an example of a learning process sequence performed, in cooperation, by the gateway 300 and the server 400. In the learning process sequence, feature information obtained as a result of performing the conversion process on a set of frames received by the gateway 300 in the on-board network of the vehicle is transmitted to the server 400, and the server 400 modifies the criterion model such that the feature information is reflected in the criterion model. Referring to Fig. 17, the learning process sequence is described below.

[0107] When the gateway 300 receives a frame (a data frame) from the bus 200a or the bus 200b in each detection window with a time length corresponding to the detection window size stored in the conversion processing unit 350 (step S1401), the gateway 300 increments the count of frames received within the detection window for corresponding one of the IDs (message IDs) (step S1402).

[0108] The conversion processing unit 350 judges an elapsed time corresponding to the detection window size (that is, an arrival of an end of one detection window) (step S1403). When an end of a detection window comes, the conversion processing unit 350 performs a conversion process based on the number of received frames (the number of counts) for each ID thereby generating feature information (step S1404). Subsequently, the gateway 300 transmits the feature information generated by the conversion processing unit 350 to the server 400 (step S1405a), and the conversion processing unit 350 clears the number of counts (step S1406). Thereafter, the gateway 300 returns to the process of detecting a next detection window (that is, the gateway 300 returns to the process in step S1401). Note that in a case where it is determined in step S1403 that an end of a detection window has not yet come, the gateway 300 returns to the process in step S1401.

[0109] In response to transmission of the feature information in step S1405a by the gateway 300, the server 400 receives the feature information (step S1405b), and the learner 430 modifies the criterion model such that the received feature information in the criterion model (step S1407). Each time feature information is received, the server 400 may modify the criterion model such that the feature information is reflected in the criterion model, or a plurality of pieces of received feature information may be accumulated in the data accumulation unit 420, and the learner 430 may update the criterion model such that the plurality of pieces of feature information are reflected at a time in the criterion model. In this learning process sequence, the criterion model is updated such that the feature information associated with a frame received in a normal state in the on-board network of the vehicle is reflected in the criterion model thereby allowing the criterion model to be used as the criterion in terms of the frequency of occurrence of frames appearing on the bus of the on-board network of the vehicle. The criterion model is defined, for example, individually for each piece of vehicle identification information acquired from vehicles. The criterion model may be defined, for example, for each vehicle. However, the same criterion model may be shared by vehicles of the same vehicle type. That is, there is a criterion model corresponding to a vehicle to which information indicating a detection window size is transmitted by the server 400 depending on the vehicle identification information from the vehicle, and model information indicating this criterion model is transmitted to the vehicle in a model update process sequence described later. The modification of the criterion model such that the feature information is reflected in the criterion model may be performed, for example, by updating the criterion model via machine learning using the feature information.

[0110] Referring to Fig. 18, an example of a detection window with a time length corresponding to the detection window size used in the learning process sequence and an example of feature information generated by the conversion process are described below.

[0111] In the conversion processing unit 350 of the gateway 300, feature information based on the number of frames received in the detection window from the bus is identified for each of periods (for each of detection windows T1, T2, and T3) each having a time length corresponding to the detection window size. In Fig. 18, by way of example, a feature vector whose components indicate the numbers of received frames counted for the respective IDs is identified as feature information. In Fig. 18, a frame with an ID of 1 is denoted by ID1, a frame with an ID of 2 is denoted by ID2, and so on. The feature vector is a vector whose components respectively indicate, for example, the number of frames (the counts) of ID1 received in the detection window, the number of frames of ID2 received in the detection window, the number of frames of ID3 received in the detection window, and the number of frames of ID4 received in the detection window. The number of components of the vector is equal to, for example, the total number of all message IDs that appear on the bus. In the example of the feature vector illustrated in Fig. 18, components respectively indicating the numbers of frames of ID1, ID2, ID3, and ID4 are arranged in this order. In a detection window T1, the number of received frames is 1 for each of ID1, ID2, and ID3, while the number of received frames is 0 for ID4, and thus the feature vector in the detection window T1 is given as [1, 1, 1, 0,...]. On the other hand, in a detection window T2, the number of received frames is 1 for each of ID1, ID2, and ID4, while the number of received frames is 0 for ID3, and thus the feature vector in the detection window T2 is given as [1, 1, 0, 1,...]. In a detection window T3, the number of received frames is 1 for each of ID1 and ID3, while the number of received frames is 0 for each of ID2 and ID4, and thus the feature vector in the detection window T3 is given as [1, 0, 1, 0,...]. The gateway 300 and the server 400 may cooperate in an arbitrary manner in performing the process (the conversion process and the like) to modify the criterion model of the server 400 such that the number of frames received by the gateway 300 within the period with the detection window size as counted individually for the respective IDs. In the conversion process, principal component analysis or the like may be used to reduce the dimension (the number of components) of the feature vector serving as the feature information.

[0112] In the server 400, when the criterion model is updated so as to reflect the feature information, for example, a conversion may be performed to make it possible to efficiently detect an abnormality in the gateway 300 by using a particular model similar to the criterion model. For example, the server 400 may perform a conversion such that a set of feature vectors with reduced dimension serving as the feature information sequentially acquired from the gateway 300 has a data structure such as a k-dimensional tree or the like that is suitable for calculating a nearest neighbor distance.

[1.18 Model update process sequence]



[0113] Fig. 19 illustrates an example of a model update process sequence performed, in cooperation, by the gateway 300 and the server 400. In the model update process sequence, the criterion model updated in the server 400 is reflected in the particular model stored in the gateway 300 of the vehicle. Referring to Fig. 19, the model update process sequence is described below. The model update process sequence is executed at an arbitrary time (for example, once every day).

[0114] The server 400 judges whether the criterion model has been updated as a result of the learning process sequence (whether a change in the content of the criterion model has occurred) (step S1501). In a case where the criterion model has been updated, the server 400 transmits model information indicating the updated criterion model to the gateway 300 (step S1502a). In response, the gateway 300 receives the model information indicating the criterion model (step S1502b).

[0115] Upon receiving the model information, the abnormality detection processor 370 in the gateway 300 updates the particular model stored in the model storage 371 according to the model information (step S1503). As a result, the particular model becomes identical, for example, to the criterion model in the server 400.

[1.19 Abnormality detection process sequence]



[0116] Fig. 20 illustrates an example of an abnormality detection process sequence performed, in cooperation, by the gateway 300 and the server 400. The abnormality detection process sequence is executed, for example, at a stage where the vehicle is used. The abnormality detection process sequence includes a process in which the gateway 300 monitors frames transmitted on the buss 200a and 200b of the on-board network of the vehicle and detects an abnormality by making a judgment using the particular model as to whether the state is abnormal. Via the model update process sequence described above, the particular model becomes identical to the criterion model updated in the learning process sequence described above. Note that the learning process sequence described above may be performed before the abnormality detection process sequence (for example, before the vehicle is used, and more particularly, when the vehicle is produced or subjected to testing or the like). Alternatively, the learning process sequence may be performed in parallel to the abnormality detection process sequence when the vehicle is used. Referring to Fig. 20, the abnormality detection process sequence is described below.

[0117] In the gateway 300, when a frame is received, (step S1601), the conversion processing unit 350 counts the number of frames received in a detection window with a detection window size for each ID (step S1602), and the conversion processing unit 350 performs the conversion process to generate, for example, a feature vector serving as feature information (step S1603). The process from step S1601 to step S1602 is performed repeatedly in each detection window. At the end of each detection window, step S1603 is performed to generate feature information, and the counter that counts the number of received frames for each ID is cleared.

[0118] Next, in the gateway 300, the abnormality detection processor 370 receives feature information generated by the conversion processing unit 350 and judges whether the feature information is consistent or inconsistent with the criterion indicated by the particular model stored in the model storage 371 (step S1604). That is, the abnormality detection processor 370 performs an operation process using the feature information and the particular model, and makes a judgment based on a result of the operation process as to whether the feature information is inconsistent with the criterion indicated by the feature information (that is, whether there is an abnormality). An example of the operation process is to calculate the nearest neighbor distance of the feature vector (see Fig. 18) serving as the feature information received from the conversion processing unit 350 to the criterion (for example, the distribution of the feature vector in the normal state) indicated by the particular model represented in a data structure such as a k-dimensional tree or the like, and compare the calculated nearest neighbor distance with a threshold value. For example, when the nearest neighbor distance distributes according to the normal distribution, if the nearest neighbor distance is out of a range defined by a threshold value, for example a range of a standard deviation times a particular value (for example, 3) from the average defined by a threshold value, then it is judged that there is an abnormality.

[0119] In a case where it is determined in step S1604 that the feature information is not inconsistent with the criterion indicated by the particular model (that is, the feature information is consistent with the criterion), the gateway 300 judges that the state is normal (step S1605), and the gateway 300 does not transmit particular information to the server 400. On the other hand, in a case where it is judged that the feature information is inconsistent with the criterion indicated by the particular model, the gateway 300 judges that the state is abnormal (step S1606), and the gateway 300 transmits an abnormality detection result to the server 400 (step S1607a).

[0120]  When the server 400 receives the abnormality detection result (step S1607b), the server 400 stores the abnormality detection result as a log (step S1608).

[1.20 Effects of first embodiment]



[0121] In the abnormality detection system 10 according to the first embodiment, the gateway 300 functioning as the abnormality detection apparatus installed in the vehicle transmits the vehicle identification information for identifying the vehicle to the server 400, and, based on a response returned from the server 400, the gateway 300 determine the detection window size (the unit time within which the number of frames received is counted to detect an abnormality). This makes it possible to make an accurate detection of an abnormality of an on-board network using the detection window size determined properly for each vehicle. Furthermore, in the abnormality detection system 10, to learn the model (the particular model or the criterion model) used in judging (detecting) an abnormality, the conversion process to generate the feature vector of the received frame is performed by the gateway 300 thereby allowing a reduction in the amount of data transmitted between the gateway 300 and the server 400. In the conversion process, it may be allowed to reduce the dimension of the feature vector by principal component analysis or the like, which makes it possible to further reduce the amount of transmission data, and thus, as a result, it becomes possible to reduce the amount of calculation in the abnormal detection based on the model. Furthermore, the server 400 may accumulate data (feature information received from vehicles) and construct the model (updating the criterion model or the like) such that the feature information is reflected in the model thereby making it possible to construct the optimum model without being limited by a limited resource of the gateway 300 installed in the vehicle. Furthermore, the criterion model constructed (updated) by the server 400 is acquired by the gateway 300 and is used to make the judgment (detection) as to an abnormality thereby making it possible to quickly judge whether there is an abnormality in the vehicle (that is, to detect an abnormality). The gateway 300 then notifies the server 400 of the abnormality detection result. The server 400 stores the abnormality detection result as a log, which makes it possible to manage the vehicle. Furthermore, it becomes possible to construct a better criterion model based on the abnormality detection result. Furthermore, for example, in a case where the vehicle identification information indicates the vehicle type, the server 400 may collect feature information from a plurality of vehicles of the same vehicle type and may properly construct the criterion model for this vehicle type such that it becomes possible to distinguish a normal state and a state in which an attack to this type occurs. The server 400 may transmit the model information indicating the criterion model to the gateway 300 of vehicles of this same type thereby making it possible for each vehicle of this type to properly detect an abnormality based on a particular model similar to the criterion model. Furthermore, when an abnormality is detected, it becomes possible to perform various processes to handle the abnormality (such as generating a warm, controlling the running of the vehicle so as to achieve safety, or the like).

(Second Embodiment)



[0122] A description is given below as an embodiment, which is a modification to the on-board network system of the vehicle in the abnormality detection system according to the first embodiment described above.

[0123] In the first embodiment, the detection window size is determined by the gateway 300 of the vehicle via the communication with the server 400 located outside the vehicle, and feature information based on the number of frames received in a time period corresponding to the detection window size counted individually for each ID is transmitted to the server 400 to allow it to update, via learning, the criterion model serving as the basis of the particular model used in detecting an abnormality in the on-board network. In contrast, in an example according to the second embodiment described below, a detection window size used in detecting an abnormality is determined independently by an abnormality detection apparatus of an on-board network system of a vehicle (that is, independently of a server located outside the vehicle).

[2.1 Configuration of on-board network system]



[0124] Fig. 21 illustrates a configuration of an on-board network system in a vehicle according to the present embodiment. In Fig. 21, elements similar to those in the first embodiment (see Fig. 1) are referred to by the same symbols as in Fig. 1, and a description thereof is omitted.

[0125] The on-board network system of the vehicle illustrated in Fig. 21 includes an ECU 100a, an ECU 100b, an ECU 100c, an ECU 100d, buss 200a and 200b, and a gateway 1300 (example of an abnormality detection apparatus). Each ECU is capable of transmitting and receiving frames via the bus 200a or 200b of the vehicle according to the CAN protocol.

[0126] The gateway 1300 is an abnormality detection apparatus obtained by partially modifying the gateway 300 according to the first embodiment described above, and elements which are not described below are similar to those of the gateway 300.

[0127] The gateway 1300 is connected to buses 200a and 200b, and has a function of transferring a frame received from one bus to the other bus, and a function of detecting an abnormality by making a judgment based on the frame received from the bus (for example, by judging whether the current state is an abnormal state in which an attack frame is flowing through the bus). The gateway 1300 also has a function of determining a detection window size for use in the abnormality detection (the judgment as to whether there is an abnormality or not), and a function of updating a particular model for use in the abnormality detection depending on feature information in terms of the number of frames received by the on-board network within the detection window having a time period equal to the detection window size.

[2.2 Configuration of gateway 1300]



[0128] Fig. 22 is a diagram illustrating a configuration of the gateway 1300. The gateway 1300 includes a frame transmission/reception unit 310, a frame interpreter 320, a reception ID judgement unit 330, an acceptance ID list storage 340, a processing unit 1350, a vehicle identification information storage 361, an abnormality detection processor 1370, a model storage 1371, a transfer processor 380, a transfer rule storage 381, a frame generator 390, a detection window size determination unit 1440, a detection window size identification table storage 450, a learner 1430, and an abnormality detection result storage 1460. Each function of each of these constituent elements is realized, for example, by a communication circuit in the gateway 1300, a processor or a digital circuit that executes a control program stored in a memory, or the like. Note that elements similar to those of the gateway 300 illustrated in Fig. 9 or elements similar to those of the server 400 illustrated in Fig. 12 are denoted in Fig. 22 by the same symbols as those in Fig. 9 or Fig. 12, and a description thereof is omitted.

[0129] The detection window size determination unit 1440 functions as a determiner that determines the detection window size. The detection window size determination unit 1440 determines, depending on the vehicle identification information stored in the vehicle identification information storage 361, the detection window size using the detection window size identification table (see Fig. 13) stored in the detection window size identification table storage 450, and notifies the processing unit 1350 of the determined detection window size.

[0130] The processing unit 1350 is a processing unit obtained by partially modifying the conversion processing unit 350 according to the first embodiment described above. The processing unit 1350 stores a detection window size notified from the detection window size determination unit 1440, and makes a conversion based on a value of an ID field notified from the frame interpreter 320 such that a set of frames sequentially received from the bus 200a or 200b (a set of values of the ID field sequentially notified) in each detection window with a time length corresponding to the detection window size is converted to feature information indicating the number of frames received in the detection window for each ID (for each message ID) (that is, the count values obtained by counting the frames received in the detection window with the detection window size individually for the respective IDs), and processing unit 1350 periodically sends the feature information to the learner 1430. That is, the processing unit 1350 functions as an identifier that identifies feature information. Furthermore, the processing unit 1350 sequentially sends, to the abnormality detection processor 1370, the feature information of frames based on the number of frames sequentially received from the bus 200a or 200b within the detection window with the detection window size.

[0131] The model storage 1371 stores a particular model (a model indicating a criterion in terms of the frequency of occurrence of data frames appearing on a bus of the on-board network of the vehicle).

[0132] The learner 1430 constructs the particular model based on the feature information notified from the processing unit 1350, and stores the constructed particular model in the model storage 1371. That is, the learner 1430 updates the particular model stored in the model storage 1371 based on the feature information. The updating of the particular model by the learner 1430 may be performed in a similar manner to the manner of updating the criterion model by the learner 430 according to the first embodiment described above. The learner 1430 may sequentially update the particular model, for example, by machine learning, for example, based on sequentially notified feature information.

[0133] The abnormality detection processor 1370 receives the feature information generated by the processing unit 1350 based on the value of the ID field notified from the frame interpreter 320, and the abnormality detection processor 1370 performs an operation process using the received feature information and the particular model stored in the model storage 1371 and makes a judgment based on a result of the operation process as to whether there is an abnormality or not. That is, the abnormality detection processor 1370 functions as a judger that judges, by performing the operation process using the feature information and the particular model, whether the feature information associated with a set of frames received from the bus is consistent with the criterion indicated by the particular model. In the judgment, when the feature information, in which the number of received data frames within the detection window size for each ID is reflected, is consistent with the criterion indicated by the particular model (for example, the criterion indicating the frequency of occurrence of data frames in the normal state), the state is judged as normal, while when the criterion is not satisfied (that is, when the feature information is inconsistent with the criterion), the state is judged as abnormal. The abnormality detection processor 370 stores a result of the judgment by the operation process as to the abnormality (that is, an abnormality detection result) as a log in the abnormality detection result storage 1460.

[2.3 Detection window size determination sequence]



[0134]  Fig. 23 illustrates an example of a detection window size determination sequence in the gateway 1300. Referring to Fig. 23, the detection window size determination sequence is described below. The timing of executing the detection window size determination sequence may be, for example, when the gateway 1300 is installed in the vehicle (for example, when the vehicle is produced), or another timing or a plurality of timings may be employed. For example, the detection window size determination sequence may be executed each time the vehicle is used (for example, each time the engine of the vehicle is started or each time an accessory is turned on (ACC-ON), or the like), or each time a particular time elapses (for example, one every day). Note that steps similar to those in Fig. 16 are denoted in Fig. 23 by the same symbols as those in Fig. 16, and a description thereof is omitted.

[0135] The gateway 1300 acquires vehicle identification information (step S1301).

[0136] Next, the gateway 1300 determines the detection window size using a detection window size identification table (see Fig. 13) according to the vehicle identification information acquired in step S1301 (step S2303). The gateway 1300 stores the determined detection window size such that the detection window size is allowed to be used when the processing unit 1350 performs the conversion process. The gateway 1300 may having a function of communicating with the outside of the vehicle. In this case, the detection window size identification table may be acquired from the outside of the vehicle via communication, or the detection window size identification table may be acquired by reading it from a storage medium or the like.

[2.4 Learning process sequence]



[0137] Fig. 24 illustrates an example of the learning process sequence performed in the gateway 1300. In the learning process sequence, the gateway 1300 updates the particular model stored in the model storage 1371 by performing learning based the feature information obtained by performing the conversion process on a set of frames received from the bus 200a or 200b. Referring to Fig. 24, the learning process sequence is described below. Note that steps similar to those in Fig. 17 are denoted in Fig. 24 by the same symbols as those in Fig. 17, and a description thereof is omitted.

[0138] Each time the gateway 1300 receives a frame from the bus 200a or the bus 200b in each detection window with a time length equal to the detection window size (step S1401), the gateway 1300 increments the count of frames received within the detection window for corresponding one of the IDs (step S1402).

[0139] When a time corresponding to the detection window size has elapsed (when the end of a detection window comes), the processing unit 1350 generates the feature information by performing the conversion process based on the number (the count) of received frames for each ID (step S1404).

[0140] The gateway 1300 modifies the particular model stored in the model storage 1371 such that the feature information generated by the processing unit 1350 is reflected in the particular model (step S2407). It is assumed that the learning process sequence modifies the particular model such that the feature information associated with frames received in the normal sate in the on-board network is reflected in the particular model and thus such that the particular model provides a criterion in terms of the frequency of occurrence of frames on the bus of the on-board network. The modifying of the particular model such that the feature information is reflected in the particular model may be accomplished, for example, by updating the particular model via machine learning using the feature information. Note that the processing unit 1350 may employ, as the feature information, a feature vector including components indicate the numbers of frames received within the detection window for the respective message IDs as with the conversion processing unit 350 according to the first embodiment described above. The processing unit 1350 may reduce the dimension of the feature vector by using the principal component analysis or the like in the conversion process. When the particular model is modified such that the feature information is reflected in the particular model, for example, the learner 1430 may perform a conversion process such that it becomes possible to efficiently perform the abnormality detection using the particular model. For example, in the modification of the particular model so as to reflect the feature information, the learner 1430 converts the set of feature vectors so as to have a data structure such as a k-dimensional tree or the like suitable for calculating the nearest neighbor distance.

[0141] After the process in step S2407, the gateway 1300 clears the count value (step S1406), and returns to the process in step S1401.

[2.5 Abnormality detection process sequence]



[0142] Fig. 25 illustrates an example of the abnormality detection process sequence performed in the gateway 1300. The abnormality detection process sequence is executed, for example, at a stage where the vehicle is used. In the abnormality detection process sequence, the gateway 1300 monitors frames transmitted on the buss 200a and 200b of the on-board network of the vehicle, and detects an abnormality by making a judgment using the particular model as to whether an abnormal state occurs. Note that the learning process sequence described above may be performed before the abnormality detection process sequence (for example, before the vehicle is used, and more particularly, when the vehicle is produced or subjected to testing or the like). Alternatively, the learning process sequence may be performed in parallel to the abnormality detection process sequence when the vehicle is used. Referring to Fig. 25, the abnormality detection process sequence is described below. Note that steps similar to those in Fig. 20 are denoted in Fig. 25 by the same symbols as those in Fig. 20, and a description thereof is omitted.

[0143] In the gateway 1300, when a frame is received, (step S1601), the processing unit 1350 counts the number of frames received in a detection window with a detection window size for each ID (step S1602), and the conversion processing unit 1350 performs the conversion process to generate, for example, a feature vector serving as feature information (step S1603). The process from step S1601 to step S1602 is performed repeatedly in each detection window. At the end of each detection window, step S1603 is performed to generate feature information, and the counter that counts the number of received frames for each ID is cleared.

[0144] Next, in the gateway 1300, the abnormality detection processor 1370 receives feature information generated by the processing unit 1350 and judges whether the feature information is consistent or inconsistent with a criterion indicated by a particular model stored in the model storage 1371 (step S1604).

[0145] In a case where it is determined in step S1604 that the feature information is not inconsistent with the criterion indicated by the particular model (that is, the feature information consistent with the criterion), the gateway 1300 judges that the state is normal (step S1605). On the other hand, in a case where it is judged that the feature information is inconsistent with the criterion indicated by the particular model, the gateway 1300 judges that the state is abnormal (step S1606), and the gateway 1300 stores a judgment result as a log (step S2608). Note that the gateway 1300 may use this judgment result in machine learning (for example, supervised learning) or the like thereby updating the particular model.

[2.6 Effects of second embodiment]



[0146] The abnormality detection apparatus (the gateway 1300) according to the second embodiment is capable of determining, without communicating with a server or the like, the detection window size (the unit time in which the number of received frames is counted to detect an abnormality) such that vehicle identification information for identifying the vehicle in which the abnormality detection apparatus is installed is acquired and the detection window size is determined depending on the acquired vehicle identification information. This makes it possible for the gateway 1300 to accurately detect an abnormality in the on-board network by using the detection window size suitable for the vehicle in which the gateway 1300 is installed. That is, it becomes possible for the gateway 1300 to construct a particular model (update the particular model or the like) such that the feature information generated based on monitoring of the on-board network is reflected in the particular model, and make a judgment (detection) on the abnormality using the particular model, which makes it possible to quickly judge whether the state is abnormal in the vehicle (that is, to detect an abnormality). Furthermore, the gateway 1300 is capable of storing, as a log, a result of the judgment as to the abnormality such that the judgment result is used.

(Other Modifications)



[0147] The first and second embodiments have been described above as examples of the technique according to the present disclosure. For example, modifications described below also fall in the scope of aspects of the present disclosure. For example, modifications described below also fall in the scope of aspects of the present disclosure.
  1. (1) In the embodiments described above, by way of example, detection windows each having a time length corresponding to the determined detection window size occur successively without overlapping each other (see Fig. 18). However, the detection windows which are period corresponding to the detection window size do not necessarily need to occur without overlapping. As illustrated in Fig. 26, the gateway (the abnormality detection apparatus) may count the number of frames received from a bus individually for each ID also in a detection window TA which partially overlap a detection window T1 and may generate a feature vector whose components indicate the numbers of received frames (the counts) for the respective IDs, and may employ the resultant feature vector as feature information. In this case, for example, the gateway may transmit, to the server, the feature information together with information indicating an offset time indicating a difference between a start time of the detection window TA and a reference start time (for example, a start time of a preceding detection window T1). Furthermore, for example, the start time of each detection window with a length corresponding to the detection window size (for example, 10 ms) may be set such that the start time occurs at fixed time intervals (for example, every 1 ms). Furthermore, the start time of the detection window may be set such that the detection window starts when a frame of a particular ID is received from a bus.
  2. (2) In the embodiments described above, by way of example, the gateway 300 or 1300 having the capability of transferring a data frame (a message) serves as the abnormality detection apparatus that detects an abnormality. However, the abnormality detection apparatus does not necessarily need to have the transfer capability, but an apparatus that is connected to one or more buses but that does not have the transfer capability may be used as the abnormality detection apparatus. The abnormality detection apparatus may be an ECU having an abnormality detection function and also an additional function other than the abnormality detection function. Furthermore, for example, the abnormality detection apparatus may not have one or more constituent elements in the gateway 300 or 1300. In this case, the one or more constituent elements in the gateway 300 or 1300 may be moved to another ECU.
  3. (3) In the embodiments described above, the data frame (message) according to the CAN protocol is described in the standard ID format (see Fig. 2). Alternatively, an extended ID format may be used, and the message ID may be an extended ID or the like in the extended ID format. The CAN protocol used in the embodiments described above may be interpreted in a broad sense. That is, the CAN protocol may include derivative protocols such as TTCAN (Time-Triggered CAN), CANFD (CAN with Flexible DataRate), and the like.
  4. (4) In the first embodiment described above, by way of example, the gateway 300 includes the external communication unit 360. However, communication may be performed via a head unit or another ECU (an apparatus having a function of communication with the outside of the vehicle) connected to the on-board network. The head unit is an ECU having a function of communicating with the outside of the vehicle to achieve, for example, a multimedia playback function, car navigation function, or the like. In the on-board network, in a case where a diagnostic tool (failure diagnosis tool) or the like connected to a diagnostic port such as OBD2 (On-Board Diagnostics2) or the like has a function of communicating with the server 400, the gateway 300 may communicate with the server 400 via this diagnostic tool.
  5. (5) In the embodiments described above, the gateways 300 and 1300 each judge that the state is abnormal when the feature information based on the number of frames received in a period corresponding to the detection window size, individually counted for each ID, is inconsistent with the criterion indicated by the particular model. For example, the content indicated by the particular model may be inverted, and the judgment may be performed such that when the feature information is consistent (not inconsistent) with the particular model, it is judged that the state is abnormal, while when the feature information is inconsistent with the particular model, it is judged that the state is normal. In the first embodiment described above, by way of example, only when the abnormality detection result indicates an abnormality, the gateway 300 transmits the abnormality detection result to the server 400, and the server 400 stores the abnormality detection result. However, the abnormality detection result may be stored also when the abnormality detection result indicates a normality.
  6. (6) In the embodiments described above, by way of example, the gateways 300 and 1300 count, individually for each ID, the number of data frames received from the bus within the detection window which is the period corresponding to the detection window size, and generate the feature information based on the number (the count) of received data frames. Alternatively, the feature information may be generated based on the total count altogether for all IDs (the total number of received data frames altogether for all IDs). In this case, the number of received data frames may be counted altogether regardless of the IDs. The criterion model or the particular model may be constructed in a form corresponding to the feature information generated in the above-described manner (that is, the criterion model or the particular model may be constructed so as to indicate the criterion in terms of the frequency of occurrence of frames without distinguishing the IDs).
  7. (7) In the embodiments described above, by way of example, the particular model indicates the criterion to be compared with the feature information based on the number of frames received by the gateway 300 or 1300 from the bus in the period corresponding to the detection window size (that is, the particular model indicates the criterion to be satisfied by the feature information). Alternatively, the particular model may be constructed so as to indicate a criterion to be compared with a frame received from the bus. In this case, steps S1602 and S1603 in Fig. 20 and Fig. 25 may be removed, and a judgment may be performed in step S1604 as to whether a frame received from the bus is consistent (or inconsistent) with the criterion indicated by the particular model. In the first embodiment described above, by way of example, the gateway 300 performs the conversion process to generate the feature information and transmits the generated feature information to the server 400 (for example, in steps S1404 and S1405a). Alternatively, the gateway 300 may transmit the ID and the reception time of each frame received from the bus to the server 400, and the conversion process may be performed by the server 400.
  8. (8) The log associated with the abnormality detection result according to the embodiments described above may be stored in an apparatus (for example, an apparatus dedicated to storing data installed in the vehicle, a head unit having a sufficiently large storage space, or the like) other than the server 400 and the gateway 1300. The information described in the log may be read out as required and may be used in managing the vehicle or designing or building the model used in detecting an abnormality.
  9. (9) In the embodiments described above, it is assumed by way of example that the gateway and other ECUs are apparatuses which include, for example, a digital circuit such as a processor, a memory, or the like, an analog circuit, a communication circuit, or the like. However they may include other hardware components such as a hard disk apparatus, a display, a keyboard, a mouse, or the like. In each apparatus according to any embodiment described above, instead of realizing functions by software by executing control programs stored in a memory by a processor, functions may be realized by dedicated hardware (a digital circuit or the like).
  10. (10) Part or all of the constituent elements of each apparatus in the embodiment described above may be implemented in a single system LSI (Large Scale Integration). The system LSI is a super-multifunction LSI produced such that a plurality of parts are integrated on a single chip. More specifically, the system LSI is a computer system including a microprocessor, a ROM, a RAM, and so on. A computer program is stored in the RAM. In the system LSI, the microprocessor operates according to the computer program thereby achieving the function of the system LSI. Each of the constituent elements of each apparatus described above may be integrated separately on a single chip, or part of all of the apparatus may be integrated on a single chip. The LSI here may be referred to as an IC, a system LSI, a super LSI, or an ultra LSI depending on a difference in the degree of integration. The technique of implementing an integrated circuit is not limited to the LSI and may be realized by using a dedicated circuit or a general-purpose processor. In addition, a FPGA (Field Programmable Gate Array) that may be programmed after the manufacture of the LSI or a reconfigurable processor in which the connections and the settings of circuit cells disposed inside the LSI may be reconfigured may be used. If future integrated circuit technology replaces LSIs as a result of the advancement of semiconductor technology or other derivative technology, the functional blocks may be integrated using the future integrated circuit technology. Biotechnology can also be applied.
  11. (11) Part or all of the constituent elements of each apparatus described above may be implemented in the form of an IC card attachable to the apparatus or in the form of a single module. The IC card or the module is a computer system including a microprocessor, a ROM, a RAM, and so on. The IC card or the module may include the super-multifunction LSI described above. In the IC card or the module, the microprocessor operates according to the computer program thereby achieving the function of the IC card or the module. The IC card or the module may be configured so as to be resistant against tampering.
  12. (12) In an aspect of the present disclosure, for example, the abnormality detection method may include all or part of the procedure illustrated in Fig. 14 to Fig. 17, Fig. 19, Fig. 20, Fig. 23 to Fig. 25, or elsewhere. For example, the abnormality detection method may be an abnormality detection method for detecting an abnormality in an on-board network system, the on-board network system including a plurality of ECUs that transmit and receive messages via a bus in a vehicle according to a CAN protocol, the abnormality detection method including determining a unit time (for example, a time corresponding to the detection window size), performing an operation process using feature information based on the number of messages received via the bus within the determined unit time and using a particular model indicating a criterion in terms of a message occurrence frequency and making a judgment according to a result of the operation process as to an abnormality. The unit time may be determined, for example, based on vehicle identification information, identification information identifying a person or the like related to the vehicle, or other information. The message includes a message ID indicating a message type, and the abnormality detection method includes the steps of, for example, determining the unit time based on the vehicle identification information for identifying the vehicle (for example, step S1305, S2303 or the like), identifying, as the feature information, a feature vector including elements which correspond to respective message IDs and each of which indicates the number of messages of the corresponding one of message IDs received from the bus within the unit time determined in the determining step (per the unit time determined most recently in a case where the determination is performed a plurality of times) (for example, step S1404 or the like), and performing an operation process using the feature information identified in the identifying step and using a particular model and then making the judgment as to an abnormality according to a result of the operation process (for example, step S1604 or the like). For example, the abnormality detection method further includes the step of sequentially updating the particular model based on a plurality of pieces of feature information sequentially identified in the identifying step (for example, step S1503, S2407 or the like). In an aspect of the present disclosure, a process associated with the abnormality detection method may be a computer program realized by a computer, or may be a digital signal according to the computer program. In an aspect, the present disclosure may be implemented by a computer readable storage medium, such as a flexible disk, a hard disk, a CD-ROM, an MO disk, a DVD disk, a DVD-ROM disk, a DVD-RAM disk, a BD (Blu-ray Disc), a semiconductor memory, or the like in which the computer program or the digital signal are stored. The present disclosure may be implemented by the digital signal stored in the storage medium described above. In an aspect, the present disclosure may be implemented by transmitting the computer program or the digital signal via a telecommunication line, a wired or wireless communication line, a network typified by the Internet, data broadcasting, or the like. In an aspect, the present disclosure may be implemented by a computer system including a microprocessor and a memory, wherein the computer program is stored in the memory and the microprocessor operates according to the computer program. The program or the digital signal may be stored in the storage medium, and the storage medium may be transported, or the program or the digital signal may be transferred via the network or the like thereby allowing the present disclosure to be implemented in another computer system.
  13. (13) Any embodiment realized by an arbitrary combination of constituent elements and functions disclosed above in the embodiments and modifications also fall in the scope of the present disclosure.

Industrial Applicability



[0148] The present disclosure is applicable to detection of an attack to an on-board network.

Reference Signs List



[0149] 

10 abnormality detection system

40 network

100a engine ECU

100b brake ECU

100c door open/close sensor ECU

100d door open/close sensor ECU

101 engine

102 brake

103 door open/close sensor

104 door open/close sensor

110, 310 frame transmission/reception unit

120, 320 frame interpreter

130, 330 acceptance ID judgment unit

140, 340 acceptance ID list storage

150 frame processor

160 data acquisition unit

170, 390 frame generator

200a, 200b bus

300, 1300 gateway (abnormality detection apparatus)

350, 1350 processing unit

360 external communication unit

361 vehicle identification information storage

370, 1370 abnormality detection processor

371, 1371 model storage

380 transfer processor

381 transfer rule storage

400 server

410 communicator

420 data accumulation unit

430, 1430 learner

440 detection window size identification unit

450 detection window size identification table storage

460, 1460 abnormality detection result storage

1440 detection window size determination unit



[0150] A first example is an abnormality detection method for detecting an abnormality in an on-board network system, the on-board network system including a plurality of electronic control units that transmit and receive messages via a bus in a vehicle according to a CAN (Controller Area Network) protocol, the abnormality detection method comprising:

determining a unit time; and

judging whether there is an abnormality according to a result of an operation process performed using feature information and a particular model indicating a criterion in terms of a message occurrence frequency, the feature information determined based on the number of messages received from the bus within the determined unit time.



[0151] A second example is the abnormality detection method according to the first example, wherein the message includes a message ID indicating a message type,

and wherein the abnormality detection method comprises the steps of performing the determination of the unit time,

identifying, as the feature information, a feature vector including components assigned to the respective message IDs and respectively indicating numbers of messages of the assigned message IDs received from the bus within the unit time determined in the determining step, and

performing the judging according to a result of the operation process performed using the particular model and the feature information identified in the identifying step.



[0152] A third example is the abnormality detection method according to the second example, wherein in the determining step, the unit time is determined based on the vehicle identification information for identifying the vehicle.

[0153] A fourth example is the abnormality detection method according to the third example, wherein the vehicle identification information indicates a manufacturer of the vehicle.

[0154] A fifth example is the abnormality detection method according to the third example, wherein the vehicle identification information indicates a type of the vehicle.

[0155] A sixth example is the abnormality detection method according to the third example, wherein the vehicle identification information is information that distinguishes the vehicle from the other vehicles.

[0156] A seventh example is the abnormality detection method according to one of the third through sixth examples, wherein in the determining step, the unit time is determined to be equal to a transmission period of one type of message which is the shortest among a plurality of different types of messages to be transmitted in a normal state via an in-vehicle bus in an on-board network system of a vehicle included in a set of vehicles identified by the vehicle identification information.

[0157] An eighth example is the abnormality detection method according to one of the third through seventh examples, wherein in the judging step, the operation process is performed using the particular model corresponding to the vehicle identification information.

[0158] A ninth example is the abnormality detection method according to one of the second through eighth claims, wherein

in the identifying step, the feature information is identified based on the number of messages received from the bus within the unit time determined in the determining step, the identifying being performed sequentially every period with a length equal to the determined unit time, and

in the judging step, the operation process is performed using the particular model and each piece of feature information sequentially identified in the identifying step,

and wherein the abnormality detection method further comprises the step of sequentially updating the particular model based on the plurality of pieces of feature information sequentially identified in the identifying step.



[0159] A tenth example is the abnormality detection method according to one of the second through ninth examples, wherein

in the determining, the unit time is determined in the vehicle based on information defined when the vehicle was produced, and

in the identifying, the feature information is identified in the vehicle.



[0160] An eleventh example is the abnormality detection method according to one of the second through ninth examples, wherein

in the determining step, the unit time is determined in the vehicle when an engine or an accessory of the vehicle is turned on, and

in the identifying step, the feature information is identified in the vehicle.



[0161] A twelfth example is the abnormality detection method according to one of the second through ninth examples, wherein

in the determining step, the unit time is determined every predefined time period,

in the identifying step, the feature information is identified based on the number of messages received from the bus within a unit time determined most recently in the determining step, the identifying being performed sequentially every period with a length equal to the unit time determined most recently, and

in the judging step, the operation process is performed on each piece of feature information sequentially identified in the identifying step using the particular model and each piece of feature information.



[0162] A thirteenth example is the abnormality detection method according to the first example, wherein

the message includes a message ID indicating a message type, and

the feature information indicates the total number of all messages received from the bus within the determined unit time.



[0163] A fourteenth example is an abnormality detection apparatus that detects an abnormality, the abnormality detection apparatus being connected to a bus in an on-board network system, the on-board network system including a plurality of electronic control units that transmit and receive messages via the bus in a vehicle according to a CAN (Controller Area Network) protocol, the abnormality detection apparatus comprising:

a receiver that receives a message from the bus;

a determiner that determines a unit time;

an identifier that identifies feature information based on the number of messages received by the receiver within the unit time determined by the determiner; and

a judger that judges whether there is an abnormality depending on a result of an operation process performed using the feature information identified by the identifier and a particular model indicating a criterion in terms of a message occurrence frequency.



[0164] A fifteenth example is an abnormality detection system including a vehicle and a server,

the vehicle including an on-board network system and an abnormality detection apparatus, the on-board network system including a plurality of electronic control units that transmit and receive messages via a bus in the vehicle according to a CAN (Controller Area Network) protocol, the abnormality detection apparatus being connected to the bus,

the abnormality detection apparatus comprising:

a receiver that receives a message from the bus;

a determiner that transmits vehicle identification information for identifying the vehicle to the server and determines a unit time based on a response returned from the server;

an identifier that identifies feature information based on the number of messages received by the receiver within the unit time determined by the determiner; and

a judger that judges whether there is an abnormality depending on a result of an operation process performed using the feature information identified by the identifier and a particular model indicating a criterion in terms of a message occurrence frequency.

the server including a communicator that receives vehicle identification information from the vehicle and transmits, to the vehicle, information indicating a unit time identified based on the vehicle identification information.



[0165] A sixteenth example is the abnormality detection system according to the fifteenth example, wherein

the server further includes a learner that acquires particular information based on the number of messages received from a bus in an on-board network system of one or more vehicles in a set of vehicles identified by the vehicle identification information, and updates, based on the particular information, a criterion model indicating a criterion in terms of message occurrence frequency,

the communicator transmits, to the vehicle, information indicating the criterion model updated by the learner,

the abnormality detection apparatus updates the particular model based on the information indicating the criterion model received from the server, and

the judger performs an operation process using the feature information and the updated particular model and performs the judgment as to whether the state is abnormal or not.




Claims

1. An abnormality detection method for detecting an abnormality in an abnormality detection apparatus (300, 1300) in an on-board network system, the on-board network system including a plurality of electronic control units (100a - 100d) that transmit and receive messages via a network (200a, 200b), wherein each of the plurality of electronic control units transmits messages periodically at fixed intervals, the abnormality detection method comprising:

determining (S1305) a unit time;

counting (S1602) the number of messages received from the network (200a, 200b) in a detection window with the determined unit time;

generating (S1603), at the end of the detection window, feature information based on the number of messages received from the network (200a, 200b); and

judging (S1604) whether there is an abnormality according to a result of an operation process performed using the feature information and a particular model indicating a criterion in terms of a message occurrence frequency.


 
2. The abnormality detection method according to claim 1, wherein
each message includes a ID indicating a message type,
and wherein the abnormality detection method comprises the steps of performing the determination (S1305) of the unit time;
counting (S1602) the number of messages received from the network (200a, 200b) in the detection window individually for each ID;
identifying (S1603), as the feature information, a feature vector including components assigned to the respective IDs and respectively indicating the numbers of messages of the assigned IDs received from the network within the detection window with the unit time determined in the determining step, and
performing the judging (S1604) according to a result of the operation process performed using the particular model and the feature information identified in the identifying step.
 
3. The abnormality detection method according to claim 2, wherein in the determining step (S1305), the unit time is determined based on the vehicle identification information for identifying the vehicle.
 
4. The abnormality detection method according to claim 3, wherein the vehicle identification information indicates a manufacturer of the vehicle.
 
5. The abnormality detection method according to claim 3, wherein the vehicle identification information indicates a type of the vehicle.
 
6. The abnormality detection method according to claim 3, wherein the vehicle identification information is information that distinguishes the vehicle from the other vehicles.
 
7. The abnormality detection method according to one of claims 3 to 6, wherein in the determining step (S1305), the unit time is determined to be equal to a transmission period of one type of message, whose transmission period is the shortest among a plurality of different types of messages to be transmitted in a normal state via an in-vehicle network in an on-board network system of a vehicle included in a set of vehicles identified by the vehicle identification information.
 
8. The abnormality detection method according to one of claims 3 to 7, wherein in the judging step (S1604), the operation process is performed using the particular model corresponding to the vehicle identification information.
 
9. The abnormality detection method according to one of claims 2 to 8, wherein
in the identifying step (S1603), the feature information is identified based on the number of messages received from the network (200a, 200b) within the detection window with the unit time determined in the determining step, the counting step (S1602) and the identifying step (S1603) being performed sequentially every period with a length equal to the determined unit time, and
in the judging step (S1604), the operation process is performed using the particular model and each piece of feature information sequentially identified in the identifying step,
and wherein the abnormality detection method further comprises the step of sequentially updating (S1503) the particular model based on the plurality of pieces of feature information sequentially identified in the identifying step (S1603).
 
10. The abnormality detection method according to one of claims 2 to 9, wherein
in the determining step (S1305), the unit time is determined in the vehicle based on information defined when the vehicle was produced, and
in the identifying step (S1603), the feature information is identified in the vehicle.
 
11. The abnormality detection method according to one of claims 2 to 9, wherein
in the determining step (S1305), the unit time is determined in the vehicle when an engine or an accessory of the vehicle is turned on, and
in the identifying step (S1603), the feature information is identified in the vehicle.
 
12. The abnormality detection method according to one of claims 2 to 9, wherein
in the determining step (S1305), the unit time is determined every predefined time period,
in the identifying step (S1603), the feature information is identified based on the number of messages received from the network(200a, 200b) within the detection window with a unit time determined most recently in the determining step, the counting (S1602) and the identifying (S1603) being performed sequentially every period with a length equal to the unit time determined most recently, and
in the judging step (S1604), the operation process is performed on each piece of feature information sequentially identified in the identifying step using the particular model and each piece of feature information.
 
13. The abnormality detection method according to claim 1, wherein
the message includes a ID indicating a message type, and
the feature information indicates the total number of all messages received from the network within the detection window with the determined unit time.
 
14. An abnormality detection apparatus (300, 1300) that is configured to detect an abnormality, the abnormality detection apparatus being connected to a network (200a, 200b) in an on-board network system, the on-board network system including a plurality of electronic control units (100a - 100d) that transmit and receive messages via the network (200a, 200b), wherein each of the plurality of electronic control units transmits messages periodically at fixed intervals, the abnormality detection apparatus (300 1300) comprising:

a receiver (310) that is configured to receive a message from the network (200a, 200b);

a determiner (360, 1440) that is configured to determine a unit time;

an identifier (350, 1350) that is configured to count the number of messages received from the network (200a, 200b) in a detection window with the determined unit time, and to generate, at the end of the detection window, feature information based on the number of messages received from the network (200a, 200b) by the receiver (310) ; and

a judger (370, 1370) that is configured to judge whether there is an abnormality depending on a result of an operation process performed using the feature information identified by the identifier (350,1350) and a particular model indicating a criterion in terms of a message occurrence frequency.


 
15. An abnormality detection system (10) including a vehicle and a server (400),
the vehicle including an on-board network system and an abnormality detection apparatus (300) according to claim 14, the on-board network system including a plurality of electronic control units (100a - 100d) that transmit and receive messages via a network (200a, 200b), wherein each of the plurality of electronic control units transmits messages periodically at fixed intervals, the abnormality detection apparatus (300) being connected to the network (200a, 200b), and
the server (400) includes a communicator (410) that is configured to receive vehicle identification information from the vehicle and to transmit, to the vehicle, information indicating a unit time identified based on the vehicle identification information.
 
16. The abnormality detection system (10) according to claim 15, wherein
the server (400) further includes a learner (430) that is configured to acquire particular information based on the number of messages received from a network (200a, 200b) in an on-board network system of one or more vehicles in a set of vehicles identified by the vehicle identification information, and updates, based on the particular information, a criterion model indicating a criterion in terms of message occurrence frequency,
the communicator (410) is configured to transmit, to the vehicle, information indicating the criterion model updated by the learner,
the abnormality detection apparatus (300) is configured to update the particular model based on the information indicating the criterion model received from the server (400), and
the judger (370) is configured to perform an operation process using the feature information and the updated particular model and to perform the judgment as to whether the state is abnormal or not.
 




Drawing

































































REFERENCES CITED IN THE DESCRIPTION



This list of references cited by the applicant is for the reader's convenience only. It does not form part of the European patent document. Even though great care has been taken in compiling the references, errors or omissions cannot be excluded and the EPO disclaims all liability in this regard.

Patent documents cited in the description